home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_actor_oldlady.cog < prev    next >
Text File  |  1999-11-15  |  1KB  |  59 lines

  1. # Jones 3D Cog Script
  2. #
  3. # actor_OldLady.cog
  4. #
  5. # [RT]
  6. #
  7. # (C) 1999 LucasArts Entertainment Company LLC. All Rights Reserved
  8. #
  9. # ===================================================================
  10.  
  11. symbols
  12.  
  13.     message        created
  14.     message        damaged
  15.  
  16.     model        head0=head_ol_asound.3do            local
  17.     model        head1=head_ol_amsound.3do            local
  18.     model        head2=head_ol_osound.3do            local
  19.  
  20.     sound        hurtSnd=inxw001.wav                    local    # "Be careful, young man."
  21.  
  22.     thing        lady                                local
  23.  
  24.     int            bTalking=0                            local
  25.  
  26. end
  27.  
  28. # ===================================================================
  29.  
  30. code
  31.  
  32. created:
  33.  
  34.     lady = GetSenderRef();
  35.  
  36.     # Heads!
  37.     SetThingVoiceHeads(lady, "llhead", "", "head_ol_asound.3do", "head_ol_amsound.3do", "head_ol_osound.3do");
  38.     return;
  39.  
  40. # -------------------------------------------------------------------
  41.  
  42. damaged:
  43.  
  44.     if (GetThingParent(GetSourceRef()) != GetLocalPlayerThing()) return;
  45.  
  46.     if (bTalking) return;
  47.  
  48.     bTalking = 1;
  49.  
  50.     lady = GetSenderRef();
  51.  
  52.     # Start the voice & wait...
  53.     PlayVoice(lady, hurtSnd, 1.0, 1);
  54.  
  55.     bTalking = 0;
  56.  
  57.     return;
  58.  
  59. end